Skip to content

feat(core): [Logs and Metrics Enable Flags 14] Warn for legacy Metrics configuration - #5955

Open
adinauer wants to merge 3 commits into
feat/warn-legacy-metrics-manifestfrom
feat/warn-legacy-metrics-external
Open

feat(core): [Logs and Metrics Enable Flags 14] Warn for legacy Metrics configuration#5955
adinauer wants to merge 3 commits into
feat/warn-legacy-metrics-manifestfrom
feat/warn-legacy-metrics-external

Conversation

@adinauer

@adinauer adinauer commented Aug 13, 2026

Copy link
Copy Markdown
Member

PR Stack (Logs and Metrics Enable Flags)


📜 Description

Continues parsing nullable metrics.enabled external configuration and emits tailored migration warnings during SentryOptions.merge for explicit true and false values.

The obsolete value is not applied. Manual Sentry.metrics() capture remains active for either value, while absent configuration emits no warning.

💡 Motivation and Context

The aggregate Metrics enable flag has been removed. Keeping nullable external parsing temporarily lets users of sentry.properties, environment variables, and system properties receive a targeted migration warning instead of having obsolete configuration silently ignored.

💚 How did you test it?

  • ./gradlew :sentry:test
  • ./gradlew spotlessApply apiDump
  • Added tests for absent, explicit true, and explicit false configuration
  • Verified both legacy values leave manual Metrics capture active

📝 Checklist

  • I added GH Issue ID & Linear ID
  • I added tests to verify the changes.
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled.
  • I updated the docs if needed.
  • I updated the wizard if needed.
  • Review from the native team if needed.
  • No breaking change or entry added to the changelog.
  • No breaking change for hybrid SDKs or communicated to hybrid SDKs.

🔮 Next steps

Add equivalent migration warnings for the legacy Spring Boot Metrics property.

#skip-changelog

⚠️ Merge this PR using a merge commit (not squash). Only the collection branch is squash-merged into main.

Emit tailored migration warnings for explicit metrics.enabled values while preserving manual Metrics capture regardless of the obsolete setting.

Co-Authored-By: Claude <noreply@anthropic.com>
@github-actions

github-actions Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor
Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.

Generated by 🚫 dangerJS against 57aee1b

@sentry

sentry Bot commented Aug 13, 2026

Copy link
Copy Markdown

📲 Install Builds

Android

🔗 App Name App ID Version Configuration
SDK Size io.sentry.tests.size 8.52.0 (1) release

⚙️ sentry-android Build Distribution Settings

@github-actions

github-actions Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Performance metrics 🚀

  Plain With Sentry Diff
Startup time 403.88 ms 489.52 ms 85.64 ms
Size 0 B 0 B 0 B

Previous results on branch: feat/warn-legacy-metrics-external

Startup times

Revision Plain With Sentry Diff
d46c6b2 358.94 ms 379.40 ms 20.46 ms
a94d6f0 299.57 ms 375.19 ms 75.62 ms

App size

Revision Plain With Sentry Diff
d46c6b2 0 B 0 B 0 B
a94d6f0 0 B 0 B 0 B

@adinauer
adinauer requested a review from 0xadam-brown as a code owner August 13, 2026 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant